Optimal. Leaf size=105 \[ \sqrt {a+\frac {c}{x^2}+\frac {b}{x}} x+\frac {b \tanh ^{-1}\left (\frac {2 a+\frac {b}{x}}{2 \sqrt {a} \sqrt {a+\frac {c}{x^2}+\frac {b}{x}}}\right )}{2 \sqrt {a}}-\sqrt {c} \tanh ^{-1}\left (\frac {b+\frac {2 c}{x}}{2 \sqrt {c} \sqrt {a+\frac {c}{x^2}+\frac {b}{x}}}\right ) \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.06, antiderivative size = 105, normalized size of antiderivative = 1.00, number of steps
used = 7, number of rules used = 6, integrand size = 16, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.375, Rules used = {1356, 746, 857,
635, 212, 738} \begin {gather*} x \sqrt {a+\frac {b}{x}+\frac {c}{x^2}}+\frac {b \tanh ^{-1}\left (\frac {2 a+\frac {b}{x}}{2 \sqrt {a} \sqrt {a+\frac {b}{x}+\frac {c}{x^2}}}\right )}{2 \sqrt {a}}-\sqrt {c} \tanh ^{-1}\left (\frac {b+\frac {2 c}{x}}{2 \sqrt {c} \sqrt {a+\frac {b}{x}+\frac {c}{x^2}}}\right ) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 212
Rule 635
Rule 738
Rule 746
Rule 857
Rule 1356
Rubi steps
\begin {align*} \int \sqrt {a+\frac {c}{x^2}+\frac {b}{x}} \, dx &=-\text {Subst}\left (\int \frac {\sqrt {a+b x+c x^2}}{x^2} \, dx,x,\frac {1}{x}\right )\\ &=\sqrt {a+\frac {c}{x^2}+\frac {b}{x}} x-\frac {1}{2} \text {Subst}\left (\int \frac {b+2 c x}{x \sqrt {a+b x+c x^2}} \, dx,x,\frac {1}{x}\right )\\ &=\sqrt {a+\frac {c}{x^2}+\frac {b}{x}} x-\frac {1}{2} b \text {Subst}\left (\int \frac {1}{x \sqrt {a+b x+c x^2}} \, dx,x,\frac {1}{x}\right )-c \text {Subst}\left (\int \frac {1}{\sqrt {a+b x+c x^2}} \, dx,x,\frac {1}{x}\right )\\ &=\sqrt {a+\frac {c}{x^2}+\frac {b}{x}} x+b \text {Subst}\left (\int \frac {1}{4 a-x^2} \, dx,x,\frac {2 a+\frac {b}{x}}{\sqrt {a+\frac {c}{x^2}+\frac {b}{x}}}\right )-(2 c) \text {Subst}\left (\int \frac {1}{4 c-x^2} \, dx,x,\frac {b+\frac {2 c}{x}}{\sqrt {a+\frac {c}{x^2}+\frac {b}{x}}}\right )\\ &=\sqrt {a+\frac {c}{x^2}+\frac {b}{x}} x+\frac {b \tanh ^{-1}\left (\frac {2 a+\frac {b}{x}}{2 \sqrt {a} \sqrt {a+\frac {c}{x^2}+\frac {b}{x}}}\right )}{2 \sqrt {a}}-\sqrt {c} \tanh ^{-1}\left (\frac {b+\frac {2 c}{x}}{2 \sqrt {c} \sqrt {a+\frac {c}{x^2}+\frac {b}{x}}}\right )\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.18, size = 131, normalized size = 1.25 \begin {gather*} \frac {x \sqrt {a+\frac {c+b x}{x^2}} \left (2 \sqrt {a} \sqrt {c+x (b+a x)}+4 \sqrt {a} \sqrt {c} \tanh ^{-1}\left (\frac {\sqrt {a} x-\sqrt {c+x (b+a x)}}{\sqrt {c}}\right )-b \log \left (b+2 a x-2 \sqrt {a} \sqrt {c+x (b+a x)}\right )\right )}{2 \sqrt {a} \sqrt {c+x (b+a x)}} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A]
time = 0.02, size = 121, normalized size = 1.15
method | result | size |
default | \(\frac {\sqrt {\frac {a \,x^{2}+b x +c}{x^{2}}}\, x \left (-2 \sqrt {c}\, \ln \left (\frac {2 c +b x +2 \sqrt {c}\, \sqrt {a \,x^{2}+b x +c}}{x}\right ) \sqrt {a}+b \ln \left (\frac {2 \sqrt {a \,x^{2}+b x +c}\, \sqrt {a}+2 a x +b}{2 \sqrt {a}}\right )+2 \sqrt {a \,x^{2}+b x +c}\, \sqrt {a}\right )}{2 \sqrt {a \,x^{2}+b x +c}\, \sqrt {a}}\) | \(121\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Failed to integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 0.40, size = 590, normalized size = 5.62 \begin {gather*} \left [\frac {4 \, a x \sqrt {\frac {a x^{2} + b x + c}{x^{2}}} + \sqrt {a} b \log \left (-8 \, a^{2} x^{2} - 8 \, a b x - b^{2} - 4 \, a c - 4 \, {\left (2 \, a x^{2} + b x\right )} \sqrt {a} \sqrt {\frac {a x^{2} + b x + c}{x^{2}}}\right ) + 2 \, a \sqrt {c} \log \left (-\frac {8 \, b c x + {\left (b^{2} + 4 \, a c\right )} x^{2} + 8 \, c^{2} - 4 \, {\left (b x^{2} + 2 \, c x\right )} \sqrt {c} \sqrt {\frac {a x^{2} + b x + c}{x^{2}}}}{x^{2}}\right )}{4 \, a}, \frac {2 \, a x \sqrt {\frac {a x^{2} + b x + c}{x^{2}}} - \sqrt {-a} b \arctan \left (\frac {{\left (2 \, a x^{2} + b x\right )} \sqrt {-a} \sqrt {\frac {a x^{2} + b x + c}{x^{2}}}}{2 \, {\left (a^{2} x^{2} + a b x + a c\right )}}\right ) + a \sqrt {c} \log \left (-\frac {8 \, b c x + {\left (b^{2} + 4 \, a c\right )} x^{2} + 8 \, c^{2} - 4 \, {\left (b x^{2} + 2 \, c x\right )} \sqrt {c} \sqrt {\frac {a x^{2} + b x + c}{x^{2}}}}{x^{2}}\right )}{2 \, a}, \frac {4 \, a x \sqrt {\frac {a x^{2} + b x + c}{x^{2}}} + 4 \, a \sqrt {-c} \arctan \left (\frac {{\left (b x^{2} + 2 \, c x\right )} \sqrt {-c} \sqrt {\frac {a x^{2} + b x + c}{x^{2}}}}{2 \, {\left (a c x^{2} + b c x + c^{2}\right )}}\right ) + \sqrt {a} b \log \left (-8 \, a^{2} x^{2} - 8 \, a b x - b^{2} - 4 \, a c - 4 \, {\left (2 \, a x^{2} + b x\right )} \sqrt {a} \sqrt {\frac {a x^{2} + b x + c}{x^{2}}}\right )}{4 \, a}, \frac {2 \, a x \sqrt {\frac {a x^{2} + b x + c}{x^{2}}} - \sqrt {-a} b \arctan \left (\frac {{\left (2 \, a x^{2} + b x\right )} \sqrt {-a} \sqrt {\frac {a x^{2} + b x + c}{x^{2}}}}{2 \, {\left (a^{2} x^{2} + a b x + a c\right )}}\right ) + 2 \, a \sqrt {-c} \arctan \left (\frac {{\left (b x^{2} + 2 \, c x\right )} \sqrt {-c} \sqrt {\frac {a x^{2} + b x + c}{x^{2}}}}{2 \, {\left (a c x^{2} + b c x + c^{2}\right )}}\right )}{2 \, a}\right ] \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int \sqrt {a + \frac {b}{x} + \frac {c}{x^{2}}}\, dx \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F(-2)]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Exception raised: TypeError} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 0.13, size = 100, normalized size = 0.95 \begin {gather*} x\,\sqrt {\frac {1}{x^2}}\,\sqrt {a\,x^2+b\,x+c}-\sqrt {c}\,x\,\ln \left (\frac {2\,c+2\,\sqrt {c}\,\sqrt {a\,x^2+b\,x+c}+b\,x}{x}\right )\,\sqrt {\frac {1}{x^2}}+\frac {b\,x\,\ln \left (\frac {\frac {b}{2}+\sqrt {a}\,\sqrt {a\,x^2+b\,x+c}+a\,x}{\sqrt {a}}\right )\,\sqrt {\frac {1}{x^2}}}{2\,\sqrt {a}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________